package com.msmall.base.message;

public class Message implements java.io.Serializable {

	private static final long serialVersionUID = 4284903982003297934L;
	
	private String message;

	private String position;
	
	public Message(){};
	
	public Message(String position, String message){
		this.setPosition(position);
		this.setMessage(message);
	}
	
	public String getMessage() {
		return message;
	}

	public void setMessage(String message) {
		this.message = message;
	}
	
	public String getPosition() {
		return position;
	}

	public void setPosition(String position) {
		this.position = position;
	}

	public boolean equals(Message obj){
		if(obj == null)
			return false;
		if(this == obj)
			return true;
		try{
			if(this.position.equals(obj.getPosition()) && this.message.equals(obj.getMessage()))
				return true;
		}catch(Exception e){
			return false;
		}
		return false;
	}
}
